package mx.utils;

extern class URLUtil {
	static var SERVER_NAME_TOKEN : String;
	static var SERVER_PORT_TOKEN : String;
	static function getFullURL(rootURL : String, url : String) : String;
	static function getPort(url : String) : UInt;
	static function getProtocol(url : String) : String;
	static function getServerName(url : String) : String;
	static function getServerNameWithPort(url : String) : String;
	static function hasUnresolvableTokens() : Bool;
	static function isHttpURL(url : String) : Bool;
	static function isHttpsURL(url : String) : Bool;
	static function objectToString(object : Dynamic, ?separator : String, ?encodeURL : Bool) : String;
	static function replacePort(uri : String, newPort : UInt) : String;
	static function replaceProtocol(uri : String, newProtocol : String) : String;
	static function replaceTokens(url : String) : String;
	static function stringToObject(string : String, ?separator : String, ?decodeURL : Bool) : Dynamic;
	static function urisEqual(uri1 : String, uri2 : String) : Bool;
}
